viewport: Request 2x border-width
authorBenjamin Otte <otte@redhat.com>
Wed, 30 Apr 2014 06:47:00 +0000 (08:47 +0200)
committerBenjamin Otte <otte@redhat.com>
Thu, 1 May 2014 12:51:27 +0000 (14:51 +0200)
It's nice that bugs get pointed out in code comments. Fixing them would
probably have been preferrable though.

gtk/gtkviewport.c

index 7f75bea9a05c7bd7e6bf63cc7848ac06ef21bf5d..20838af1ecd5e15fce20c39f622c3764d6c23ab4 100644 (file)
@@ -1025,10 +1025,7 @@ gtk_viewport_get_preferred_size (GtkWidget      *widget,
 
   child = gtk_bin_get_child (GTK_BIN (widget));
 
-  /* XXX This should probably be (border_width * 2); but GTK+ has
-   * been doing this with a single border for a while now...
-   */
-  minimum = gtk_container_get_border_width (GTK_CONTAINER (widget));
+  minimum = 2 * gtk_container_get_border_width (GTK_CONTAINER (widget));
 
   context = gtk_widget_get_style_context (GTK_WIDGET (widget));
   state = gtk_widget_get_state_flags (GTK_WIDGET (widget));